package com.baiyun.mapper;

import com.baiyun.entity.Orders;
import org.apache.ibatis.annotations.Mapper;

import java.time.LocalDateTime;
import java.util.Date;
import java.util.List;

@Mapper
public interface OrderMapper {
    /**
     * 查询所有订单
     * @return
     */
    List<Orders> selectAllOrder();

    /**
     * 添加订单
     * @param orders
     */
    void addOrder(Orders orders);

    /**
     * 修改订单
     * @param orders
     */
    void updateOrder(Orders orders);

    /**
     * 删除订单
     * @param oid
     */
    void deleteOrder(Integer oid);

    /**
     * 根据id查询订单
     * @param oid
     * @return
     */
    Orders selectById(Integer oid);

    /**
     * 根据茶名模糊搜索订单
     * @param tname
     * @return
     */
    List<Orders> slectByTeaName(String tname);

    Orders selectOrder(Orders orders);
}
